import 'package:flutter/material.dart';
import 'package:fluttertoast/fluttertoast.dart';

showToast(String message) {
  Fluttertoast.showToast(
      msg: message,
      gravity: ToastGravity.CENTER,
      toastLength: Toast.LENGTH_LONG);
}

showTextToast(String message) {
    Fluttertoast.showToast(
      msg: message,
      toastLength: Toast.LENGTH_SHORT, // 短时间
      gravity: ToastGravity.BOTTOM, // 在底部显示
      timeInSecForIosWeb: 1, // iOS 和 Web 的持续时间
      backgroundColor: Colors.black, // 背景颜色
      textColor: Colors.white, // 文字颜色
      fontSize: 16.0, // 字体大小
    );
  }